﻿using System;
using System.ServiceModel;
using System.Windows.Forms;

namespace Revit同步插件.UI
{
  public partial class StartupForm : Form
  {
    public StartupForm()
    {
      InitializeComponent();
    }

    public StartupForm(ServiceHost host) : this()
    {
      this.host = host;
    }

    private void button1_Click(object sender, EventArgs e)
    {
      host.Open();

    }
    private void button2_Click(object sender, EventArgs e)
    {
      if (host.State == CommunicationState.Opened)
      {
        host.Close();
      }
    }
    ServiceHost host;


  }
}
